#include<bits/stdc++.h>
using namespace std;
signed main() {
    int n;
    cin >> n;
    while(n--) {
        int x;
        cin >> x;

        if(x / 100000 + x / 10000 % 10 + x / 1000 % 10 == x % 10 + x % 100 / 10 + x % 1000 / 100)
            cout << "You are lucky!\n";
        else
            cout << "Wish you good luck.\n";
    }
    return 0;
}

